package com.dylearn.serve.impl.rabbitmq.listener;

import org.springframework.amqp.rabbit.annotation.RabbitListener;

/**
 * 监听器
 * */
//@Component
public class MsgListenerTopic {

    //绑定 消息队列
    @RabbitListener(queues = "topic_queue")
    public void receive(String id ){
        System.out.println("处理消息队列 -- topic_queue1 id = " + id);
    }

    //绑定 消息队列
    @RabbitListener(queues = "topic_queue2")
    public void receive2(String id ){
        System.out.println("处理消息队列 -- topic_queue2 id = " + id);
    }

}
